﻿@page "/apphost-configuration"
@using Amazon.SQS;
@using Amazon.SQS.Model;
@using Microsoft.Extensions.Options;

@inject IConfiguration configuration;

@inject IAmazonSQS sqsClient;

<PageTitle>SQS Send Message Example</PageTitle>

<h1>App Host Configuration</h1>

<p>
The list of configuration applied from the CloudFormation stack created in AppHost and assigned to project.
</p>
<ul>
    @foreach(var item in configuration.GetSection("AWS:Resources").AsEnumerable())
    {
        @if(item.Value != null)
        {
            <li><b>@item.Key:</b> @item.Value</li>
        }
    }
</ul>


<p>
Configuration applied from AppHost to AWS service clients:
</p>
<ul>
    <li><b>Profile:</b> @Environment.GetEnvironmentVariable("AWS_PROFILE")</li>
    <li><b>Region:</b> @sqsClient.Config.RegionEndpoint.SystemName</li>
</ul>
